package com.zp.self.module.level_1_问道.III_多线程.JUC;

import java.util.concurrent.atomic.AtomicIntegerArray;

/**
 * @author ：by Zeng Peng
 * @date ：Created 2022/8/5 7:45
 * @description ：
 */
public class AtomicIntegerArrayTest {
    public static void main(String[] args) {

        AtomicIntegerArray array = new AtomicIntegerArray(new int[] { 0, 0 });
        System.out.println(array);
        System.out.println(array.getAndAdd(1, 2));
        System.out.println(array);
    }
}
